//
//  BCSettingCenterClearCachaCell.m
//  GSBlockChain
//
//  Created by guoshikeji_a on 2018/12/29.
//  Copyright © 2018 guoshikeji. All rights reserved.
//

#import "BCSettingCenterClearCachaCell.h"

//
#import "BCSettingCacheManager.h"

@implementation BCSettingCenterClearCachaCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        
    }
    return self;
}


- (void)setCellModel:(SettingCenterCellModel *)cellModel {
    [super setCellModel:cellModel];
    //
    self.detailsLabel.text = nil;
    dispatch_async(dispatch_get_global_queue(0, 0), ^{
        NSString *cacheString = [[BCSettingCacheManager sharedCache] getCacheSizeString];
        dispatch_async(dispatch_get_main_queue(), ^{
            self.detailsLabel.text = cacheString;
        });
    });
}

@end
